USE [vudu]
GO
/****** Object:  StoredProcedure [dbo].[[ActivarPensum]]    Script Date: 01/29/2012 13:54:15 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

CREATE PROCEDURE [dbo].[ActivarPensum]

	@idPensum int,
	@idPeriodo int
AS
BEGIN

	Insert into PensumPeriodoAcademico (id_pensum, id_periodo)
	values (@idPensum, @idPeriodo);
	UPDATE Pensum
	SET statusPensum = 'ACTIVADO'
	WHERE id_Pensum = @idPensum;
END